files=Dir["./*.jar"]

#require 'find'
	#module Find
	  #def match(*paths)
	    #matched = []
	    #find(*paths) { |path| matched << path if yield path }
	    #return matched
	  #end
	  #module_function :match
	#end	

    open('gen3rtempcmd.txt', 'w') do |f|
	  open('gen3rtemppom.txt', 'w') do |o|
            files.each do |p|
                if File.file? p
                    filename= p[2...p.length]
                    
                    f.puts "call mvn install:install-file -Dfile=#{filename} -DgroupId=dsw.share -DartifactId=#{filename[0...p.length-6]} -Dversion=1.0 -Dpackaging=jar"
                    
                     o.puts "<dependency>"
                     o.puts "   <groupId>dsw.share</groupId>"
                     o.puts "   <artifactId>#{filename[0...p.length-6]}</artifactId>"
                     o.puts "   <version>1.0</version>"
                     o.puts "</dependency>"
                    
                 end 
             end
      end
	end

	
          


